package com.xr.miniprogram.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.xr.miniprogram.domain.MiniProgramUser;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface MiniProgramUserMapper extends BaseMapper<MiniProgramUser> {
    /**
     * 查询用户
     *
     * @param miniProgramUserId 用户主键
     * @return 用户
     */
    public MiniProgramUser selectMiniProgramUserByMiniProgramUserId(Long miniProgramUserId);

    /**
     * 查询用户
     *
     * @param openId 微信key
     * @return 用户
     */
    public MiniProgramUser selectMiniProgramUserByOpenId(String openId);

    /**
     * 查询用户列表
     *
     * @param miniProgramUser 用户
     * @return 用户集合
     */
    public List<MiniProgramUser> selectMiniProgramUserList(MiniProgramUser miniProgramUser);

    /**
     * 修改用户
     *
     * @param miniProgramUser 用户
     * @return 结果
     */
    public int updateMiniProgramUser(MiniProgramUser miniProgramUser);
}
